package cn.pconline.officialclub.entity;

import cn.pconline.autoclub.entity.Club;
import cn.pconline.autoclub.entity.EntityWithClubProp;
import java.util.Date;
import org.gelivable.dao.Column;
import org.gelivable.dao.Entity;
import org.gelivable.dao.Id;
import org.gelivable.dao.Transient;

/**
 *
 * 民间车友会加入官方车友会的申请
 *
 * @author <a href="mailto:chensy0203@163.com">chensy</a>
 */
@Entity(tableName = "oac_member_application", logChange = true)
public class OMemberApplication extends EntityKit implements EntityWithClubProp{

    /**
     * 主键
     */
    @Id
    @Column(name = "id")
    private long id;
    /**
     * 民间车友会id
     */
    @Column(name = "club_id")
    private long clubId;
    /**
     * 官方车友会id
     */
    @Column(name = "o_club_id")
    private long oClubId;
    /**
     * 审核状态(0:未审,1:已通过,-1:已拒绝,-2:自己取消)
     */
    @Column(name = "status")
    private int status;
    /**
     * 申请时间
     *
     */
    @Column(name = "create_at")
    private Date createAt;
    /**
     * 申请id
     */
    @Column(name = "create_by")
    private long createBy;
    /**
     * 审核人id
     */
    @Column(name = "audit_at")
    private Date auditAt;
    /**
     * 审核时间
     */
    @Column(name = "audit_by")
    private long auditBy;
    
    @Transient
    private Club club;
    /**
     * 未审
     */
    public static final int STATUS_UNAUDITED = 0;
    /**
     * 通过
     */
    public static final int STATUS_PASS = 1;
    /**
     * 拒绝
     */
    public static final int STATUS_REJECT = -1;
    /**
     * 自己取消
     */
    public static final int STATUS_CANCEL = -2;

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public long getClubId() {
        return clubId;
    }

    public void setClubId(long clubId) {
        this.clubId = clubId;
    }

    /**
     * 兼容geli
     *
     * @return
     */
    public long getOClubId() {
        return oClubId;
    }

    /**
     * 兼容geli
     *
     * @return
     */
    public void setOClubId(long oClubId) {
        this.oClubId = oClubId;
    }

    public long getoClubId() {
        return oClubId;
    }

    public void setoClubId(long oClubId) {
        this.oClubId = oClubId;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public Date getCreateAt() {
        return createAt;
    }

    public void setCreateAt(Date createAt) {
        this.createAt = createAt;
    }

    public long getCreateBy() {
        return createBy;
    }

    public void setCreateBy(long createBy) {
        this.createBy = createBy;
    }

    public Date getAuditAt() {
        return auditAt;
    }

    public void setAuditAt(Date auditAt) {
        this.auditAt = auditAt;
    }

    public long getAuditBy() {
        return auditBy;
    }

    public void setAuditBy(long auditBy) {
        this.auditBy = auditBy;
    }

    public Club getClub() {
        return club;
    }

    public void setClub(Club club) {
        this.club = club;
    }
    
}
